<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title>锚点链接实现轮播图</title>
		<style type="text/css">
			*{
				margin:0;
				padding:0;
			}
			img{
				display:block;
			}
			.box{
				width:1694px;
				height:200px;
				border:2px solid red;
				margin-left:300px;
				margin-top:200px;
				text-decoration: none;
				position:relative; /* 使成为第一父元素*/
			}
			.btn{
				position:absolute;
				right:20px;
				bottom:20px; 
			}
			.btn a{
				width:30px;
				height:30px;
				margin-right:10px;
				display:block;
				float:left;
				text-align:center;
				line-height: 30px;
				background-color:rgba(0,0,0,.5);
			}
			.btn a:hover{
				background-color:rgba(0,0,0,1)
			}
			.img{
				width:1694px;
				height:200px;
				overflow:hidden;
			}
		</style>
	</head>
	<body>
		<div class="box">
			<div class="btn">
				<a href="#img1">1</a>
				<a href="#img2">2</a>
				<a href="#img3">3</a>
				<a href="#img4">4</a>
			</div>
			<div class="img">
				<img src="img/pic-1.jpg" alt="图片1" id="img1">
				<img src="img/pic-2.jpg" alt="图片2" id="img2">
				<img src="img/pic-3.jpg" alt="图片3" id="img3">
				<img src="img/pic-4.jpg" alt="图片4" id="img4">
			</div>
		</div>
	</body>
</html>
